package com.project.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.project.bean.MangerBean;
import com.project.mapper.IManagerMapper;
import com.project.service.IManageService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

@Service
@Transactional
public class ManageServiceImpl implements IManageService {
      @Autowired
      private IManagerMapper mapper;
      
      @Override
      public MangerBean login(String managerName, String password) {
            QueryWrapper<MangerBean> mangerBeanQueryWrapper=new QueryWrapper<>();
            mangerBeanQueryWrapper.eq("managerName",managerName);
            mangerBeanQueryWrapper.eq("password",password);
            return mapper.selectOne(mangerBeanQueryWrapper);
      }
}
